import React, {useState} from "react";
import AwasomeSwiper from 'react-awesome-swiper'

export default function (props) {
  const [config] = useState({
    loop: true,
    autoplay: {
      delay: 5000
    },
    pagination:{
      el:'.swiper-pagination'
    }
  })


  return (
    <AwasomeSwiper className='banner' config={config}>
      <div className='swiper-wrapper'>
        {props?.pictures?.map(item=>(
          <div className='swiper-slide' key={item}>
            <img alt='banner' src={item}/>
          </div>
        ))}
      </div>
      <div className='swiper-pagination'></div>
    </AwasomeSwiper>
  )
}


